#ifndef TCPTHREAD_H
#define TCPTHREAD_H

#include <string>
#include <vector>
#include "Thread.h"

#define BUFFER_SIZE 128

using namespace std;

class TcpThread: public Thread
{
private:
	int cs;
	char szbuffer[BUFFER_SIZE];
	int ibytesrecv;
	int ibufferlen;
	int ibytessent;
public:
	TcpThread(int clientsocket) :cs(clientsocket)
	{}
	virtual void run();
	int stringToInt(string);
	int getFileSize(const string &);
	int getTextFileCount(const string &);
	vector<string> ListDirectoryContents(const char *);
	bool fileExist(const string &);
	bool isBinaryFile(const string &);
};

#endif